# -*- coding: utf-8 -*-
from rest_framework import serializers
from studentweb.models import Faculty,Major,Student

class FacultySerialzer(serializers.ModelSerializer):
    class Meta:
        model = Faculty
        fields = "__all__"


class MajorSerialzer(serializers.ModelSerializer):
    faculty = FacultySerialzer()
    class Meta:
        model = Major
        fields = "__all__"


class StudentSerialzer(serializers.ModelSerializer):
    major = MajorSerialzer()
    class Meta:
        model = Student
        fields = "__all__"